package org.example.DesignPatterns.Observer;

/**
 * @description:
 * @author: farprt
 * @create: 2022-09-25 13:30
 **/
public class PhoneFans extends Buyer {
    public PhoneFans(String name) {
        super(name);
    }

    @Override
    public void inform(String product) {
        if(product.contains("手机")){
            System.out.print(name);
            System.out.println("购买："+product);
        }
    }
}